<?php

namespace App\Api\V1\Models;

use Illuminate\Database\Eloquent\Model;

class Appinstall extends Model
{
    protected $table = 'app_install';
    public $timestamps = false;

    /*
    添加一个提问
    */

    public function addAppInstallItem($request)
    {
           $ds=[
              "app_install_id"=>'1',
              "user_agent"=>'windows',
              "ver"=>'1.2.1.0',
    			    "url"=>'http://careyshop.cn',
           ];

            $this->user_id = $ds['user_id'];
  	        $this->user_agent = $ds['user_agent'];
  	        $this->ver = $ds['ver'];
  	        $this->url = $ds['url'];
     	
       if ($this->save()) {
            return $this->toArray();
        }
        return false;
  	}
}